package wifiunion.com.notice.presenter;

import android.content.Context;


import java.util.HashMap;

import wifiunion.com.notice.NoticeContact;
import wifiunion.com.notice.NoticeModel;

/**
 * 获取识别对象列表
 * Created by Administrator on 2016/12/1.
 */

public class GetNotificationUserPresenter implements NoticeContact.Presenter, NoticeContact.Callback {

    private NoticeContact.View mView;
    private Context mContext;
    private NoticeModel mModel;


    public GetNotificationUserPresenter(Context context, NoticeContact.View view) {
        mView = view;
        mContext = context;
        mModel = new NoticeModel();
        mView.setPresenter(this);
    }

    @Override
    public void onSuccess(Object data) {

        mView.getNotificationUserSuccess(data);
    }

    @Override
    public void onServerFailed(Object errorObj) {
        mView.onError(errorObj);
    }

    @Override
    public void onNetFailed() {
        mView.onError("网络异常");
    }

    @Override
    public void start() {

    }

    @Override
    public void start(HashMap<String, Object> param1s) {

    }

    public void getNotificationUser(HashMap<String, Object> params)
    {
        mModel.getNotificationUser(params,this);
    }
}
